<% review_form = fields
# TODO: da inserire il riferimento alla recensione 
%>
<tr>
	<td class="label_cell_form"><%= label_tag "review_name", Core.human_attribute_name("name") %></td>
	<td class="label_input_form"><%= review_form.text_field :name %></td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_description", Core.human_attribute_name("description") %></td>
	<td class="label_input_form"><%= review_form.text_area :description, :rows => 5 %></td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_sites", Core.human_attribute_name("sites") %></td>
	<td class="label_input_form"><%= review_form.text_field :sites %></td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_author", Review.human_attribute_name("author") %></td>
	<td class="label_input_form"><%= review_form.text_field :author %></td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_category", Review.human_attribute_name("category") %></td>
	<td class="label_input_form"><%= select(:review, :category, Category.find(:all, :conditions => "type_core = 'review'").map {| i | i.name}) %></td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_kinds", Review.human_attribute_name("kinds") %></td>
	<td class="label_input_form">
		<%= render :partial => "/cores/kinds_field", :object => { :core => @review, :form => review_form } %>
	</td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_sites", Core.human_attribute_name("sites") %></td>
	<td class="label_input_form">
		<% sites = @review.sites.to_s.split(" , ") %>  		
			<div>
				<%= text_field_tag "review[site][]", sites.delete_at(0), :size => 30 %>
				<a rel="review" href="#" class="more_site_lnk mini_button_form" ><%=t "core.more_sites" %></a>
				<%= a = ""; sites.each{ |i| a += "<br />" + text_field_tag("review[site][]",i)}; a; %>
			</div>  		
	</td>
</tr>
<tr>
	<td class="label_cell_form"><%= label_tag "review_photo_data", Core.human_attribute_name("photo")  %></td>
	<td class="label_input_form">
			<%= render :partial => "/cores/image_field", :object => { :form => review_form, 
				:core_name => "review", :core_photo => @review_photo } %>
	</td>
</tr>

